import drag from './drag'
const scroll = Rx.Observable.fromEvent(document, 'scroll');
const video = document.getElementById('video')
const anchor = document.getElementById('anchor')
drag('video')
scroll  
    .map(() => anchor.getBoundingClientRect().bottom < 0)
    .subscribe(
        (bool) => {
            if (bool) {
                console.log(video.classList);
                // video.classList.add('video-fixed')
                video.className = 'video-fixed'
            } else {
                // video.classList.remove('video-fixed')
                video.className = 'video'
            }
        }
    )
